package writers

import (
	"fmt"
	"mig2kwdb/common"
	"strings"
)

func CreateWriter(dbConn common.DBConnectionInfo) (Writer, error) {
	switch strings.ToLower(dbConn.Dbtype) {
	case "kwdb":
		return NewKwdbWriter(dbConn)

	default:
		return nil, fmt.Errorf("unsupported database type: %s", dbConn.Dbtype)
	}
}
